package org.opens.event;

import org.springframework.context.ApplicationEvent;

/**
 * 定义事件实体类, 必须继承ApplicationEvent这个接口
 */
public class StudentEvent extends ApplicationEvent {

    private String name;

    private String message;

    /**
     * @param source 事件源
     */
    public StudentEvent(Object source) {
        super(source);
    }

    public StudentEvent(Object source, String name, String message) {
        super(source);
        this.name = name;
        this.message = message;
    }

    public String getName() {
        return name;
    }

    public void setName(String name) {
        this.name = name;
    }

    public String getMessage() {
        return message;
    }

    public void setMessage(String message) {
        this.message = message;
    }
}
